The present invention relates to computer-generated imagery and animation, and more particularly to animation techniques for using key frame animation controls to achieve path-based animation.
Animation involves the generation of a series of still images that, when played back in quick succession, appear as continuously moving. In computer animation, a rendering process is used to generate a two-dimensional image of a three-dimensional scene from a given viewpoint. Animated sequences can be created by rendering a sequence of the rendered images of a scene as a scene is gradually changed over time. A great deal of effort has been devoted to making the rendered images and the resultant animation realistic.
An object being animated is generally represented by a collection of geometric primitives, mathematical representations, and other information that describe the position, orientation, shape and behavior of the object. A set of animation control channels (also referred to as “animation variables” or “avars”) are generally associated with an animated object to facilitate animation of the object. Different values may be assigned to the animation variables at different time points or frames to control the animation of the object. For example, values assigned to the animation variables may specify the pose, including the position and orientation, of the object at different time points (frames) during the animation.
Animation variables that are used to specify the position and orientation of an object comprise translation-related parameters, including Tx (translation in X-axis), Ty (translation in Y-axis), and Tz (translation in Z-axis), and rotation-related parameters, including Rx (rotation in X-axis), Ry (rotation in Y-axis), and Rz (rotation in Z-axis). The values assigned to Tx, Ty, Tz, Rx, Ry, and Rz at a time point (a frame) define the position and orientation of the object at that time point or frame. The translation-related and rotation-related animation variables are commonly together referred to as the “transformation animation variables” associated with a model for an animated object. Values assigned to transformation animation variables may be used to construct a transformation matrix for posing the animated object
Two commonly used animation techniques are “key frame animation” and “path-based animation”. In key frame animation, an animator (or user) specifies or authors values for animation variables of an object at different time points or frames. Position and orientation of the animated object may be controlled by specifying values for the transformation animation variables for the object at various frames or time points. For example, an animator may specify that the value for Tx for frame 1 is 0, at frame 5 is 5, at frame 70 is 3, etc. The pair of a time point (expressed as a frame number) and the value specified for that frame is commonly referred to as a “knot” and the frame referred to as a key frame. In key frame animation, the animator specifies the position and orientation for an object being animated by specifying one or more knots for one or more transformation animation variables associated with the object. Knots for each animation variable are specified independently of knots for other animation variables. Accordingly, knots for Tx are specified independent of knots for Ty, and so on.
Once one or more knots have been specified for an animation variable at specific key frames, the animation system uses the specified knots to calculate intermediate values for the animation variable for the other time points (frames) for the duration of the animation. An interpolation technique (e.g., a spline function) is typically used to determine the in-between values for the animation variable based upon the knots specified by the animator. For example, if knots are specified for Tz at frames 10 and 25 and if the duration of the animation is 100 frames, then an interpolation function is used to find values for the other frames for Tz up to frame 100 based upon the values specified for frames 10 and 25. Different interpolation functions may be used including linear, cubic, B-spline, Bezier spline, Cardinal spline, Catmull-Rom splines, etc. The spline curve that is determined for the animation variable may pass through the specified knots.
In key frame animation, the interpolated spline for each animation variable for an object is calculated independently from splines for other animation variables for the object. In other words, the spline for an animation variable is generated based upon knots specified for that animation variable and is independent of knots specified for other animation variables associated with the same object. For example, the interpolation spline for Tx is determined independently from the interpolation spline for Ty or R. Accordingly, splines for the translational and rotational animation variables are animated independently with key-framed animation splines.
Animators like to use key frame animation to specify animation for an object because it gives them direct control of the animation variables for the object. Specifying a knot allows an animator to pin down both a time (frame) and a value of the animation variable at that time, thus allowing direct control of the animation variable. Animating the transformation animation variables for an object in this way pins down the object's position and orientation at specified key frames. Since the knots for each animation variable are specified independent of other animation variables and the spline for each animation variable is calculated independent from other animation variable splines, each animation variable can be independently controlled thereby giving the animator a great deal of control over the animation. For example, to pose an object, the animator may specify knots independently for the translation and rotation parameters and thereby control the animation.
However, the independent control of each animation variable provided by key frame animation is not always suitable for animating complex motions for an object where various motions and positions of the object have to be synchronized. For example, for animating a car driving along a path and changing orientation as it drives, controlling the translation and rotation animation variables independently using key frame animation is complicated and results in motion that does not look very realistic. The car appears to “skid”—which does not create a realistic animation effect for the car's motion.
Sometimes, instead of using key frame animation, it is simpler to specify animation for an object along a path. This is the focus of path-based animation. In path-based animation, the motion of an object through space is defined in terms of a path that the object follows. A path (also referred to as a “motion path”) is defined independent of the object. The path defines a route in global space along which an object will move. Accordingly, the object's motion is constrained to the path. Given a path, an animator then uses a timing spline to specify an object's position along the path. The timing spline allows the animator to specify knots to control the movement of the object along the motion path. A timing spline plots time (frames) on one axis and the distance traveled along the path along the other axis. Each knot for a timing spline identifies a key frame (time point) and a position (expressed as the distance along the path) on the path at the key frame. Using an interpolation technique, a timing spline is then generated that interpolates the knots and determines the position of the object along the path at all frames for the length of the animation sequence. By editing the timing spline, an animator can control the rate of movement of the object along the path.
In path-based animation, orientation of the object is implied or determined from the position of the object along the path. One commonly used technique is to always keep the object tangent to the path as it travels along the path. For example, the orientation of a car traveling along the path is always aligned with the direction of the path. Another technique is to always keep the object in the starting orientation as it moves along the path.
Accordingly, in path-based animation, position and timing are decoupled: animators create a path in space without regard to the timing, and then time character motion along the path using a different animation channel (a timing spline). Separate controls are thus used for defining the path and defining the motion along the path. This technique is awkward for many animators, and makes animation revisions particularly difficult, since altering the path changes its total length, which in turn alters the animator's carefully tuned timing. Animators much rather prefer the direct control offered by key frame animation, where both positioning and timing are pinned by the knots of the spline.
Accordingly, what is desired are improved techniques for solving some of the problems discussed above. Additionally, what is desired are improved techniques for reducing some of the drawbacks discussed above.